<template>
  <div id="app">
    <router-view v-if="isRouterAlive" style="height: 100%"/>
  </div>
</template>

<script>
/* eslint-disable */
export default {
  name: 'App',
  provide() {
    return {
      reload: this.reload,
    };
  },
  data() {
    return {
      isRouterAlive: true,
    };
  },
  methods: {
    reload() {
      this.isRouterAlive = false;
      this.$nextTick(function () {
         this.isRouterAlive = true;
      });
    },
  },
};
</script>

<style scoped>
  body, html{
    height: 100%;
    background-color:darkgray;
  }
  #app{
    height: 100%;
    overflow: hidden;
  }
</style>
